package gov.police.diary.service.impl;

import gov.police.diary.dao.PolicemanDao;
import gov.police.diary.model.PolPoliceman;
import gov.police.diary.service.PolicemanService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 *
 * @author nmduc
 */
@Service("PolicemanService")
public class PoliceServiceImpl implements PolicemanService {

    @Autowired
    private PolicemanDao policemanDao;

    public PolPoliceman getPoliceman(long id) {
        return this.policemanDao.getPoliceman(id);
    }

    public void savePoliceman(PolPoliceman policeman) {
        this.policemanDao.savePoliceman(policeman);
    }

    public void deletePoliceman(PolPoliceman policeman) {
        this.policemanDao.deletePoliceman(policeman);
    }

    public void updatePoliceman(PolPoliceman policeman) {
        this.policemanDao.updatePoliceman(policeman);
    }

    public PolicemanDao getPolicemanDao() {
        return policemanDao;
    }

    public void setPolicemanDao(PolicemanDao policemanDao) {
        this.policemanDao = policemanDao;
    }
}
